import request from '@/utils/request'

export function login(username, password, ticket, randstr) {
  return request({
    url: '/account/login',
    method: 'post',
    params: {
      'username': username,
      'password': password,
      'ticket': ticket,
      'randstr': randstr
    }
  })
}

export function logout() {
  console.log('logout')
  return request({
    url: '/account/logout',
    method: 'post'
  })
}

export function updatePwd(params) {
  return request({
    url: '/account/updatePwd',
    method: 'post',
    params
  })
}
